covid_on_unemp_benefit_numberのOLSとWLS
source("functions.R")df_analysis <- readr::read_csv("output/df_analysis.csv")## Rows: 1551 Columns: 273
## ─ Column specification ────────────────────────────
## Delimiter: ","
## chr (4): prefec_kanji, prefecture, prefec, prefec_kanji2
## dbl (268): id, month, year, suicide_total, suicide_male, suicide_female, su...
## date (1): date
##
## ℹ Use `spec()` to retrieve the full column specification for this data.
## ℹ Specify the column types or set `show_col_types = FALSE` to quiet this message.
# DID estimation
estimation_results <- dynamic_DID_OLS_notrend(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "total_OLS_notrend")
# Event study graph
graph_total_OLS_notrend <- event_study_graph(data = df_estimates ,
graph_title = "total_OLS_notrend")
graph_total_OLS_notrend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_total_OLS_notrend <- df_estimates #for robustness checkdf_analysis$population_total## [1] 5320 5320 5320 5320 5320 5320 5320 5320 5320 5320 5320 5320
## [13] 5286 5286 5286 5286 5286 5286 5286 5286 5286 5286 5286 5286
## [25] 5250 5250 5250 5250 5250 5250 5250 5250 5250 1278 1278 1278
## [37] 1278 1278 1278 1278 1278 1278 1278 1278 1278 1263 1263 1263
## [49] 1263 1263 1263 1263 1263 1263 1263 1263 1263 1246 1246 1246
## [61] 1246 1246 1246 1246 1246 1246 1255 1255 1255 1255 1255 1255
## [73] 1255 1255 1255 1255 1255 1255 1241 1241 1241 1241 1241 1241
## [85] 1241 1241 1241 1241 1241 1241 1227 1227 1227 1227 1227 1227
## [97] 1227 1227 1227 2323 2323 2323 2323 2323 2323 2323 2323 2323
## [109] 2323 2323 2323 2316 2316 2316 2316 2316 2316 2316 2316 2316
## [121] 2316 2316 2316 2306 2306 2306 2306 2306 2306 2306 2306 2306
## [133] 996 996 996 996 996 996 996 996 996 996 996 996
## [145] 981 981 981 981 981 981 981 981 981 981 981 981
## [157] 966 966 966 966 966 966 966 966 966 1102 1102 1102
## [169] 1102 1102 1102 1102 1102 1102 1102 1102 1102 1090 1090 1090
## [181] 1090 1090 1090 1090 1090 1090 1090 1090 1090 1078 1078 1078
## [193] 1078 1078 1078 1078 1078 1078 1882 1882 1882 1882 1882 1882
## [205] 1882 1882 1882 1882 1882 1882 1864 1864 1864 1864 1864 1864
## [217] 1864 1864 1864 1864 1864 1864 1846 1846 1846 1846 1846 1846
## [229] 1846 1846 1846 2892 2892 2892 2892 2892 2892 2892 2892 2892
## [241] 2892 2892 2892 2877 2877 2877 2877 2877 2877 2877 2877 2877
## [253] 2877 2877 2877 2860 2860 2860 2860 2860 2860 2860 2860 2860
## [265] 1957 1957 1957 1957 1957 1957 1957 1957 1957 1957 1957 1957
## [277] 1946 1946 1946 1946 1946 1946 1946 1946 1946 1946 1946 1946
## [289] 1934 1934 1934 1934 1934 1934 1934 1934 1934 1960 1960 1960
## [301] 1960 1960 1960 1960 1960 1960 1960 1960 1960 1952 1952 1952
## [313] 1952 1952 1952 1952 1952 1952 1952 1952 1952 1942 1942 1942
## [325] 1942 1942 1942 1942 1942 1942 7310 7310 7310 7310 7310 7310
## [337] 7310 7310 7310 7310 7310 7310 7330 7330 7330 7330 7330 7330
## [349] 7330 7330 7330 7330 7330 7330 7350 7350 7350 7350 7350 7350
## [361] 7350 7350 7350 6246 6246 6246 6246 6246 6246 6246 6246 6246
## [373] 6246 6246 6246 6255 6255 6255 6255 6255 6255 6255 6255 6255
## [385] 6255 6255 6255 6259 6259 6259 6259 6259 6259 6259 6259 6259
## [397] 13724 13724 13724 13724 13724 13724 13724 13724 13724 13724 13724 13724
## [409] 13822 13822 13822 13822 13822 13822 13822 13822 13822 13822 13822 13822
## [421] 13921 13921 13921 13921 13921 13921 13921 13921 13921 9159 9159 9159
## [433] 9159 9159 9159 9159 9159 9159 9159 9159 9159 9177 9177 9177
## [445] 9177 9177 9177 9177 9177 9177 9177 9177 9177 9198 9198 9198
## [457] 9198 9198 9198 9198 9198 9198 2267 2267 2267 2267 2267 2267
## [469] 2267 2267 2267 2267 2267 2267 2246 2246 2246 2246 2246 2246
## [481] 2246 2246 2246 2246 2246 2246 2223 2223 2223 2223 2223 2223
## [493] 2223 2223 2223 1056 1056 1056 1056 1056 1056 1056 1056 1056
## [505] 1056 1056 1056 1050 1050 1050 1050 1050 1050 1050 1050 1050
## [517] 1050 1050 1050 1044 1044 1044 1044 1044 1044 1044 1044 1044
## [529] 1147 1147 1147 1147 1147 1147 1147 1147 1147 1147 1147 1147
## [541] 1143 1143 1143 1143 1143 1143 1143 1143 1143 1143 1143 1143
## [553] 1138 1138 1138 1138 1138 1138 1138 1138 1138 779 779 779
## [565] 779 779 779 779 779 779 779 779 779 774 774 774
## [577] 774 774 774 774 774 774 774 774 774 768 768 768
## [589] 768 768 768 768 768 768 823 823 823 823 823 823
## [601] 823 823 823 823 823 823 817 817 817 817 817 817
## [613] 817 817 817 817 817 817 811 811 811 811 811 811
## [625] 811 811 811 2076 2076 2076 2076 2076 2076 2076 2076 2076
## [637] 2076 2076 2076 2063 2063 2063 2063 2063 2063 2063 2063 2063
## [649] 2063 2063 2063 2049 2049 2049 2049 2049 2049 2049 2049 2049
## [661] 2008 2008 2008 2008 2008 2008 2008 2008 2008 2008 2008 2008
## [673] 1997 1997 1997 1997 1997 1997 1997 1997 1997 1997 1997 1997
## [685] 1987 1987 1987 1987 1987 1987 1987 1987 1987 3675 3675 3675
## [697] 3675 3675 3675 3675 3675 3675 3675 3675 3675 3659 3659 3659
## [709] 3659 3659 3659 3659 3659 3659 3659 3659 3659 3644 3644 3644
## [721] 3644 3644 3644 3644 3644 3644 7525 7525 7525 7525 7525 7525
## [733] 7525 7525 7525 7525 7525 7525 7537 7537 7537 7537 7537 7537
## [745] 7537 7537 7537 7537 7537 7537 7552 7552 7552 7552 7552 7552
## [757] 7552 7552 7552 1800 1800 1800 1800 1800 1800 1800 1800 1800
## [769] 1800 1800 1800 1791 1791 1791 1791 1791 1791 1791 1791 1791
## [781] 1791 1791 1791 1781 1781 1781 1781 1781 1781 1781 1781 1781
## [793] 1413 1413 1413 1413 1413 1413 1413 1413 1413 1413 1413 1413
## [805] 1412 1412 1412 1412 1412 1412 1412 1412 1412 1412 1412 1412
## [817] 1414 1414 1414 1414 1414 1414 1414 1414 1414 2599 2599 2599
## [829] 2599 2599 2599 2599 2599 2599 2599 2599 2599 2591 2591 2591
## [841] 2591 2591 2591 2591 2591 2591 2591 2591 2591 2583 2583 2583
## [853] 2583 2583 2583 2583 2583 2583 8823 8823 8823 8823 8823 8823
## [865] 8823 8823 8823 8823 8823 8823 8813 8813 8813 8813 8813 8813
## [877] 8813 8813 8813 8813 8813 8813 8809 8809 8809 8809 8809 8809
## [889] 8809 8809 8809 5503 5503 5503 5503 5503 5503 5503 5503 5503
## [901] 5503 5503 5503 5484 5484 5484 5484 5484 5484 5484 5484 5484
## [913] 5484 5484 5484 5466 5466 5466 5466 5466 5466 5466 5466 5466
## [925] 1348 1348 1348 1348 1348 1348 1348 1348 1348 1348 1348 1348
## [937] 1339 1339 1339 1339 1339 1339 1339 1339 1339 1339 1339 1339
## [949] 1330 1330 1330 1330 1330 1330 1330 1330 1330 945 945 945
## [961] 945 945 945 945 945 945 945 945 945 935 935 935
## [973] 935 935 935 935 935 935 935 935 935 925 925 925
## [985] 925 925 925 925 925 925 565 565 565 565 565 565
## [997] 565 565 565 565 565 565 560 560 560 560 560 560
## [1009] 560 560 560 560 560 560 556 556 556 556 556 556
## [1021] 556 556 556 685 685 685 685 685 685 685 685 685
## [1033] 685 685 685 680 680 680 680 680 680 680 680 680
## [1045] 680 680 680 674 674 674 674 674 674 674 674 674
## [1057] 1907 1907 1907 1907 1907 1907 1907 1907 1907 1907 1907 1907
## [1069] 1898 1898 1898 1898 1898 1898 1898 1898 1898 1898 1898 1898
## [1081] 1890 1890 1890 1890 1890 1890 1890 1890 1890 2829 2829 2829
## [1093] 2829 2829 2829 2829 2829 2829 2829 2829 2829 2817 2817 2817
## [1105] 2817 2817 2817 2817 2817 2817 2817 2817 2817 2804 2804 2804
## [1117] 2804 2804 2804 2804 2804 2804 1383 1383 1383 1383 1383 1383
## [1129] 1383 1383 1383 1383 1383 1383 1370 1370 1370 1370 1370 1370
## [1141] 1370 1370 1370 1370 1370 1370 1358 1358 1358 1358 1358 1358
## [1153] 1358 1358 1358 743 743 743 743 743 743 743 743 743
## [1165] 743 743 743 736 736 736 736 736 736 736 736 736
## [1177] 736 736 736 728 728 728 728 728 728 728 728 728
## [1189] 967 967 967 967 967 967 967 967 967 967 967 967
## [1201] 962 962 962 962 962 962 962 962 962 962 962 962
## [1213] 956 956 956 956 956 956 956 956 956 1364 1364 1364
## [1225] 1364 1364 1364 1364 1364 1364 1364 1364 1364 1352 1352 1352
## [1237] 1352 1352 1352 1352 1352 1352 1352 1352 1352 1339 1339 1339
## [1249] 1339 1339 1339 1339 1339 1339 714 714 714 714 714 714
## [1261] 714 714 714 714 714 714 706 706 706 706 706 706
## [1273] 706 706 706 706 706 706 698 698 698 698 698 698
## [1285] 698 698 698 5107 5107 5107 5107 5107 5107 5107 5107 5107
## [1297] 5107 5107 5107 5107 5107 5107 5107 5107 5107 5107 5107 5107
## [1309] 5107 5107 5107 5104 5104 5104 5104 5104 5104 5104 5104 5104
## [1321] 824 824 824 824 824 824 824 824 824 824 824 824
## [1333] 819 819 819 819 819 819 819 819 819 819 819 819
## [1345] 815 815 815 815 815 815 815 815 815 1354 1354 1354
## [1357] 1354 1354 1354 1354 1354 1354 1354 1354 1354 1341 1341 1341
## [1369] 1341 1341 1341 1341 1341 1341 1341 1341 1341 1327 1327 1327
## [1381] 1327 1327 1327 1327 1327 1327 1765 1765 1765 1765 1765 1765
## [1393] 1765 1765 1765 1765 1765 1765 1757 1757 1757 1757 1757 1757
## [1405] 1757 1757 1757 1757 1757 1757 1748 1748 1748 1748 1748 1748
## [1417] 1748 1748 1748 1152 1152 1152 1152 1152 1152 1152 1152 1152
## [1429] 1152 1152 1152 1144 1144 1144 1144 1144 1144 1144 1144 1144
## [1441] 1144 1144 1144 1135 1135 1135 1135 1135 1135 1135 1135 1135
## [1453] 1089 1089 1089 1089 1089 1089 1089 1089 1089 1089 1089 1089
## [1465] 1081 1081 1081 1081 1081 1081 1081 1081 1081 1081 1081 1081
## [1477] 1073 1073 1073 1073 1073 1073 1073 1073 1073 1626 1626 1626
## [1489] 1626 1626 1626 1626 1626 1626 1626 1626 1626 1614 1614 1614
## [1501] 1614 1614 1614 1614 1614 1614 1614 1614 1614 1602 1602 1602
## [1513] 1602 1602 1602 1602 1602 1602 1443 1443 1443 1443 1443 1443
## [1525] 1443 1443 1443 1443 1443 1443 1448 1448 1448 1448 1448 1448
## [1537] 1448 1448 1448 1448 1448 1448 1453 1453 1453 1453 1453 1453
## [1549] 1453 1453 1453
# DID estimation
estimation_results <- dynamic_DID_WLS_notrend(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "total_WLS_notrend")
# Event study graph
graph_total_WLS_notrend <- event_study_graph(data = df_estimates,
graph_title = "total_WLS_notrend")
graph_total_WLS_notrend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_total_WLS_notrend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_trend(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "total_OLS_trend")
# Event study graph
graph_total_OLS_trend <- event_study_graph(data = df_estimates,
graph_title = "total_OLS_trend")
graph_total_OLS_trend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_total_OLS_trend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_trend(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "total_WLS_trend")
# Event study graph
graph_total_WLS_trend <- event_study_graph(data = df_estimates,
graph_title = "total_WLS_trend")
graph_total_WLS_trend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_total_WLS_trend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_notrend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "total_OLS_notrend")
# Event study graph
graph_total_OLS_notrend_covar <- event_study_graph(data = df_estimates,
graph_title = "total_OLS_notrend")
graph_total_OLS_notrend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_total_OLS_notrend_covar <- df_estimates #for robustness checkdf_analysis$population_total## [1] 5320 5320 5320 5320 5320 5320 5320 5320 5320 5320 5320 5320
## [13] 5286 5286 5286 5286 5286 5286 5286 5286 5286 5286 5286 5286
## [25] 5250 5250 5250 5250 5250 5250 5250 5250 5250 1278 1278 1278
## [37] 1278 1278 1278 1278 1278 1278 1278 1278 1278 1263 1263 1263
## [49] 1263 1263 1263 1263 1263 1263 1263 1263 1263 1246 1246 1246
## [61] 1246 1246 1246 1246 1246 1246 1255 1255 1255 1255 1255 1255
## [73] 1255 1255 1255 1255 1255 1255 1241 1241 1241 1241 1241 1241
## [85] 1241 1241 1241 1241 1241 1241 1227 1227 1227 1227 1227 1227
## [97] 1227 1227 1227 2323 2323 2323 2323 2323 2323 2323 2323 2323
## [109] 2323 2323 2323 2316 2316 2316 2316 2316 2316 2316 2316 2316
## [121] 2316 2316 2316 2306 2306 2306 2306 2306 2306 2306 2306 2306
## [133] 996 996 996 996 996 996 996 996 996 996 996 996
## [145] 981 981 981 981 981 981 981 981 981 981 981 981
## [157] 966 966 966 966 966 966 966 966 966 1102 1102 1102
## [169] 1102 1102 1102 1102 1102 1102 1102 1102 1102 1090 1090 1090
## [181] 1090 1090 1090 1090 1090 1090 1090 1090 1090 1078 1078 1078
## [193] 1078 1078 1078 1078 1078 1078 1882 1882 1882 1882 1882 1882
## [205] 1882 1882 1882 1882 1882 1882 1864 1864 1864 1864 1864 1864
## [217] 1864 1864 1864 1864 1864 1864 1846 1846 1846 1846 1846 1846
## [229] 1846 1846 1846 2892 2892 2892 2892 2892 2892 2892 2892 2892
## [241] 2892 2892 2892 2877 2877 2877 2877 2877 2877 2877 2877 2877
## [253] 2877 2877 2877 2860 2860 2860 2860 2860 2860 2860 2860 2860
## [265] 1957 1957 1957 1957 1957 1957 1957 1957 1957 1957 1957 1957
## [277] 1946 1946 1946 1946 1946 1946 1946 1946 1946 1946 1946 1946
## [289] 1934 1934 1934 1934 1934 1934 1934 1934 1934 1960 1960 1960
## [301] 1960 1960 1960 1960 1960 1960 1960 1960 1960 1952 1952 1952
## [313] 1952 1952 1952 1952 1952 1952 1952 1952 1952 1942 1942 1942
## [325] 1942 1942 1942 1942 1942 1942 7310 7310 7310 7310 7310 7310
## [337] 7310 7310 7310 7310 7310 7310 7330 7330 7330 7330 7330 7330
## [349] 7330 7330 7330 7330 7330 7330 7350 7350 7350 7350 7350 7350
## [361] 7350 7350 7350 6246 6246 6246 6246 6246 6246 6246 6246 6246
## [373] 6246 6246 6246 6255 6255 6255 6255 6255 6255 6255 6255 6255
## [385] 6255 6255 6255 6259 6259 6259 6259 6259 6259 6259 6259 6259
## [397] 13724 13724 13724 13724 13724 13724 13724 13724 13724 13724 13724 13724
## [409] 13822 13822 13822 13822 13822 13822 13822 13822 13822 13822 13822 13822
## [421] 13921 13921 13921 13921 13921 13921 13921 13921 13921 9159 9159 9159
## [433] 9159 9159 9159 9159 9159 9159 9159 9159 9159 9177 9177 9177
## [445] 9177 9177 9177 9177 9177 9177 9177 9177 9177 9198 9198 9198
## [457] 9198 9198 9198 9198 9198 9198 2267 2267 2267 2267 2267 2267
## [469] 2267 2267 2267 2267 2267 2267 2246 2246 2246 2246 2246 2246
## [481] 2246 2246 2246 2246 2246 2246 2223 2223 2223 2223 2223 2223
## [493] 2223 2223 2223 1056 1056 1056 1056 1056 1056 1056 1056 1056
## [505] 1056 1056 1056 1050 1050 1050 1050 1050 1050 1050 1050 1050
## [517] 1050 1050 1050 1044 1044 1044 1044 1044 1044 1044 1044 1044
## [529] 1147 1147 1147 1147 1147 1147 1147 1147 1147 1147 1147 1147
## [541] 1143 1143 1143 1143 1143 1143 1143 1143 1143 1143 1143 1143
## [553] 1138 1138 1138 1138 1138 1138 1138 1138 1138 779 779 779
## [565] 779 779 779 779 779 779 779 779 779 774 774 774
## [577] 774 774 774 774 774 774 774 774 774 768 768 768
## [589] 768 768 768 768 768 768 823 823 823 823 823 823
## [601] 823 823 823 823 823 823 817 817 817 817 817 817
## [613] 817 817 817 817 817 817 811 811 811 811 811 811
## [625] 811 811 811 2076 2076 2076 2076 2076 2076 2076 2076 2076
## [637] 2076 2076 2076 2063 2063 2063 2063 2063 2063 2063 2063 2063
## [649] 2063 2063 2063 2049 2049 2049 2049 2049 2049 2049 2049 2049
## [661] 2008 2008 2008 2008 2008 2008 2008 2008 2008 2008 2008 2008
## [673] 1997 1997 1997 1997 1997 1997 1997 1997 1997 1997 1997 1997
## [685] 1987 1987 1987 1987 1987 1987 1987 1987 1987 3675 3675 3675
## [697] 3675 3675 3675 3675 3675 3675 3675 3675 3675 3659 3659 3659
## [709] 3659 3659 3659 3659 3659 3659 3659 3659 3659 3644 3644 3644
## [721] 3644 3644 3644 3644 3644 3644 7525 7525 7525 7525 7525 7525
## [733] 7525 7525 7525 7525 7525 7525 7537 7537 7537 7537 7537 7537
## [745] 7537 7537 7537 7537 7537 7537 7552 7552 7552 7552 7552 7552
## [757] 7552 7552 7552 1800 1800 1800 1800 1800 1800 1800 1800 1800
## [769] 1800 1800 1800 1791 1791 1791 1791 1791 1791 1791 1791 1791
## [781] 1791 1791 1791 1781 1781 1781 1781 1781 1781 1781 1781 1781
## [793] 1413 1413 1413 1413 1413 1413 1413 1413 1413 1413 1413 1413
## [805] 1412 1412 1412 1412 1412 1412 1412 1412 1412 1412 1412 1412
## [817] 1414 1414 1414 1414 1414 1414 1414 1414 1414 2599 2599 2599
## [829] 2599 2599 2599 2599 2599 2599 2599 2599 2599 2591 2591 2591
## [841] 2591 2591 2591 2591 2591 2591 2591 2591 2591 2583 2583 2583
## [853] 2583 2583 2583 2583 2583 2583 8823 8823 8823 8823 8823 8823
## [865] 8823 8823 8823 8823 8823 8823 8813 8813 8813 8813 8813 8813
## [877] 8813 8813 8813 8813 8813 8813 8809 8809 8809 8809 8809 8809
## [889] 8809 8809 8809 5503 5503 5503 5503 5503 5503 5503 5503 5503
## [901] 5503 5503 5503 5484 5484 5484 5484 5484 5484 5484 5484 5484
## [913] 5484 5484 5484 5466 5466 5466 5466 5466 5466 5466 5466 5466
## [925] 1348 1348 1348 1348 1348 1348 1348 1348 1348 1348 1348 1348
## [937] 1339 1339 1339 1339 1339 1339 1339 1339 1339 1339 1339 1339
## [949] 1330 1330 1330 1330 1330 1330 1330 1330 1330 945 945 945
## [961] 945 945 945 945 945 945 945 945 945 935 935 935
## [973] 935 935 935 935 935 935 935 935 935 925 925 925
## [985] 925 925 925 925 925 925 565 565 565 565 565 565
## [997] 565 565 565 565 565 565 560 560 560 560 560 560
## [1009] 560 560 560 560 560 560 556 556 556 556 556 556
## [1021] 556 556 556 685 685 685 685 685 685 685 685 685
## [1033] 685 685 685 680 680 680 680 680 680 680 680 680
## [1045] 680 680 680 674 674 674 674 674 674 674 674 674
## [1057] 1907 1907 1907 1907 1907 1907 1907 1907 1907 1907 1907 1907
## [1069] 1898 1898 1898 1898 1898 1898 1898 1898 1898 1898 1898 1898
## [1081] 1890 1890 1890 1890 1890 1890 1890 1890 1890 2829 2829 2829
## [1093] 2829 2829 2829 2829 2829 2829 2829 2829 2829 2817 2817 2817
## [1105] 2817 2817 2817 2817 2817 2817 2817 2817 2817 2804 2804 2804
## [1117] 2804 2804 2804 2804 2804 2804 1383 1383 1383 1383 1383 1383
## [1129] 1383 1383 1383 1383 1383 1383 1370 1370 1370 1370 1370 1370
## [1141] 1370 1370 1370 1370 1370 1370 1358 1358 1358 1358 1358 1358
## [1153] 1358 1358 1358 743 743 743 743 743 743 743 743 743
## [1165] 743 743 743 736 736 736 736 736 736 736 736 736
## [1177] 736 736 736 728 728 728 728 728 728 728 728 728
## [1189] 967 967 967 967 967 967 967 967 967 967 967 967
## [1201] 962 962 962 962 962 962 962 962 962 962 962 962
## [1213] 956 956 956 956 956 956 956 956 956 1364 1364 1364
## [1225] 1364 1364 1364 1364 1364 1364 1364 1364 1364 1352 1352 1352
## [1237] 1352 1352 1352 1352 1352 1352 1352 1352 1352 1339 1339 1339
## [1249] 1339 1339 1339 1339 1339 1339 714 714 714 714 714 714
## [1261] 714 714 714 714 714 714 706 706 706 706 706 706
## [1273] 706 706 706 706 706 706 698 698 698 698 698 698
## [1285] 698 698 698 5107 5107 5107 5107 5107 5107 5107 5107 5107
## [1297] 5107 5107 5107 5107 5107 5107 5107 5107 5107 5107 5107 5107
## [1309] 5107 5107 5107 5104 5104 5104 5104 5104 5104 5104 5104 5104
## [1321] 824 824 824 824 824 824 824 824 824 824 824 824
## [1333] 819 819 819 819 819 819 819 819 819 819 819 819
## [1345] 815 815 815 815 815 815 815 815 815 1354 1354 1354
## [1357] 1354 1354 1354 1354 1354 1354 1354 1354 1354 1341 1341 1341
## [1369] 1341 1341 1341 1341 1341 1341 1341 1341 1341 1327 1327 1327
## [1381] 1327 1327 1327 1327 1327 1327 1765 1765 1765 1765 1765 1765
## [1393] 1765 1765 1765 1765 1765 1765 1757 1757 1757 1757 1757 1757
## [1405] 1757 1757 1757 1757 1757 1757 1748 1748 1748 1748 1748 1748
## [1417] 1748 1748 1748 1152 1152 1152 1152 1152 1152 1152 1152 1152
## [1429] 1152 1152 1152 1144 1144 1144 1144 1144 1144 1144 1144 1144
## [1441] 1144 1144 1144 1135 1135 1135 1135 1135 1135 1135 1135 1135
## [1453] 1089 1089 1089 1089 1089 1089 1089 1089 1089 1089 1089 1089
## [1465] 1081 1081 1081 1081 1081 1081 1081 1081 1081 1081 1081 1081
## [1477] 1073 1073 1073 1073 1073 1073 1073 1073 1073 1626 1626 1626
## [1489] 1626 1626 1626 1626 1626 1626 1626 1626 1626 1614 1614 1614
## [1501] 1614 1614 1614 1614 1614 1614 1614 1614 1614 1602 1602 1602
## [1513] 1602 1602 1602 1602 1602 1602 1443 1443 1443 1443 1443 1443
## [1525] 1443 1443 1443 1443 1443 1443 1448 1448 1448 1448 1448 1448
## [1537] 1448 1448 1448 1448 1448 1448 1453 1453 1453 1453 1453 1453
## [1549] 1453 1453 1453
# DID estimation
estimation_results <- dynamic_DID_WLS_notrend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)##
## ====================================================================
## Model 1
## --------------------------------------------------------------------
## treat_var:date_2018_01 54.534
## (37.706)
## treat_var:date_2018_02 66.710
## (37.867)
## treat_var:date_2018_03 67.786
## (39.111)
## treat_var:date_2018_04 44.764
## (38.902)
## treat_var:date_2018_05 -35.484
## (43.808)
## treat_var:date_2018_06 0.620
## (39.746)
## treat_var:date_2018_07 -39.144
## (45.930)
## treat_var:date_2018_08 -9.280
## (54.932)
## treat_var:date_2018_09 28.231
## (55.634)
## treat_var:date_2018_10 34.845
## (58.477)
## treat_var:date_2018_11 73.796
## (53.440)
## treat_var:date_2018_12 70.995
## (49.224)
## treat_var:date_2019_01 22.685
## (46.668)
## treat_var:date_2019_02 55.724
## (42.641)
## treat_var:date_2019_03 69.865
## (41.187)
## treat_var:date_2019_04 16.596
## (43.542)
## treat_var:date_2019_05 -27.187
## (51.545)
## treat_var:date_2019_06 -27.198
## (51.573)
## treat_var:date_2019_07 -77.039
## (54.570)
## treat_var:date_2019_08 -35.521
## (55.337)
## treat_var:date_2019_09 -3.736
## (51.168)
## treat_var:date_2019_10 18.613
## (49.369)
## treat_var:date_2019_11 19.917
## (19.566)
## treat_var:date_2019_12 20.027
## (15.334)
## treat_var:date_2020_02 -77.579 *
## (34.199)
## treat_var:date_2020_03 -70.748
## (46.610)
## treat_var:date_2020_04 -68.820
## (48.011)
## treat_var:date_2020_05 -23.636
## (49.438)
## treat_var:date_2020_06 -115.981
## (58.763)
## treat_var:date_2020_07 -66.541
## (56.368)
## treat_var:date_2020_08 40.349
## (58.336)
## treat_var:date_2020_09 110.490
## (60.820)
## date_2020_02:google_mobility_index_2020may -3.769 *
## (1.710)
## date_2020_03:google_mobility_index_2020may -3.499
## (2.074)
## date_2020_04:google_mobility_index_2020may -3.648
## (1.891)
## date_2020_05:google_mobility_index_2020may -1.677
## (2.135)
## date_2020_06:google_mobility_index_2020may -5.111
## (2.606)
## date_2020_07:google_mobility_index_2020may -5.411
## (2.728)
## date_2020_08:google_mobility_index_2020may -3.637
## (2.352)
## date_2020_09:google_mobility_index_2020may -1.770
## (2.002)
## date_2020_02:infection_rate_cumulative2020jun -151.728
## (104.359)
## date_2020_03:infection_rate_cumulative2020jun -132.822
## (129.289)
## date_2020_04:infection_rate_cumulative2020jun -96.116
## (132.554)
## date_2020_05:infection_rate_cumulative2020jun -148.331
## (106.808)
## date_2020_06:infection_rate_cumulative2020jun 32.626
## (171.349)
## date_2020_07:infection_rate_cumulative2020jun -56.129
## (152.290)
## date_2020_08:infection_rate_cumulative2020jun 32.706
## (155.498)
## date_2020_09:infection_rate_cumulative2020jun 46.034
## (141.429)
## date_2020_02:death_rate_cumulative2020jun 1486.315
## (1356.863)
## date_2020_03:death_rate_cumulative2020jun 1293.465
## (1619.755)
## date_2020_04:death_rate_cumulative2020jun 994.150
## (1719.860)
## date_2020_05:death_rate_cumulative2020jun 1728.661
## (1178.085)
## date_2020_06:death_rate_cumulative2020jun -618.917
## (2221.052)
## date_2020_07:death_rate_cumulative2020jun 344.999
## (1913.980)
## date_2020_08:death_rate_cumulative2020jun -369.536
## (1825.071)
## date_2020_09:death_rate_cumulative2020jun -548.566
## (1619.323)
## date_2020_02:Population_per_1_km_2_of_inhabitable_area -0.002
## (0.003)
## date_2020_03:Population_per_1_km_2_of_inhabitable_area -0.004
## (0.004)
## date_2020_04:Population_per_1_km_2_of_inhabitable_area -0.004
## (0.003)
## date_2020_05:Population_per_1_km_2_of_inhabitable_area -0.003
## (0.002)
## date_2020_06:Population_per_1_km_2_of_inhabitable_area -0.007 *
## (0.003)
## date_2020_07:Population_per_1_km_2_of_inhabitable_area -0.005
## (0.003)
## date_2020_08:Population_per_1_km_2_of_inhabitable_area -0.002
## (0.003)
## date_2020_09:Population_per_1_km_2_of_inhabitable_area 0.002
## (0.003)
## date_2020_02:Secondary_industry_ratio 17.866
## (122.297)
## date_2020_03:Secondary_industry_ratio -22.840
## (143.851)
## date_2020_04:Secondary_industry_ratio -35.435
## (145.857)
## date_2020_05:Secondary_industry_ratio -257.486
## (133.527)
## date_2020_06:Secondary_industry_ratio -204.709
## (166.859)
## date_2020_07:Secondary_industry_ratio -224.462
## (172.314)
## date_2020_08:Secondary_industry_ratio -194.296
## (174.501)
## date_2020_09:Secondary_industry_ratio -132.797
## (165.880)
## date_2020_02:Tertiary_industry_ratio -293.981
## (169.603)
## date_2020_03:Tertiary_industry_ratio -335.171
## (203.633)
## date_2020_04:Tertiary_industry_ratio -339.190
## (202.906)
## date_2020_05:Tertiary_industry_ratio -613.391 **
## (178.973)
## date_2020_06:Tertiary_industry_ratio -606.618 *
## (229.839)
## date_2020_07:Tertiary_industry_ratio -709.776 **
## (224.615)
## date_2020_08:Tertiary_industry_ratio -604.216 **
## (217.886)
## date_2020_09:Tertiary_industry_ratio -488.936 *
## (182.220)
## date_2020_02:Total_population 0.031
## (0.022)
## date_2020_03:Total_population 0.046
## (0.024)
## date_2020_04:Total_population 0.034
## (0.025)
## date_2020_05:Total_population 0.029
## (0.021)
## date_2020_06:Total_population 0.008
## (0.030)
## date_2020_07:Total_population 0.000
## (0.029)
## date_2020_08:Total_population -0.022
## (0.026)
## date_2020_09:Total_population -0.029
## (0.024)
## date_2020_02:Ratio_of_aged_population 0.402
## (0.759)
## date_2020_03:Ratio_of_aged_population 0.237
## (0.857)
## date_2020_04:Ratio_of_aged_population 0.429
## (0.771)
## date_2020_05:Ratio_of_aged_population -0.419
## (0.931)
## date_2020_06:Ratio_of_aged_population -0.810
## (1.218)
## date_2020_07:Ratio_of_aged_population -1.271
## (1.300)
## date_2020_08:Ratio_of_aged_population -1.937
## (1.203)
## date_2020_09:Ratio_of_aged_population -2.062
## (1.041)
## --------------------------------------------------------------------
## R^2 0.950
## Adj. R^2 0.943
## Num. obs. 1551
## RMSE 763.048
## N Clusters 47
## ====================================================================
## *** p < 0.001; ** p < 0.01; * p < 0.05
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "total_WLS_notrend")
# Event study graph
graph_total_WLS_notrend_covar <- event_study_graph(data = df_estimates,
graph_title = "total_WLS_notrend")
graph_total_WLS_notrend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_total_WLS_notrend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_trend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "total_OLS_trend")
# Event study graph
graph_total_OLS_trend_covar <- event_study_graph(data = df_estimates,
graph_title = "total_OLS_trend")
graph_total_OLS_trend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_total_OLS_trend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_trend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "total_WLS_trend")
# Event study graph
graph_total_WLS_trend_covar <- event_study_graph(data = df_estimates,
graph_title = "total_WLS_trend")
graph_total_WLS_trend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_total_WLS_trend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_notrend(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_total_OLS_notrend")
# Event study graph
graph_yoy_total_OLS_notrend <- event_study_graph(data = df_estimates,
graph_title = "yoy_total_OLS_notrend")
graph_yoy_total_OLS_notrend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_total_OLS_notrend<- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_notrend(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_total_WLS_notrend")
# Event study graph
graph_yoy_total_WLS_notrend <- event_study_graph(data = df_estimates,
graph_title = "yoy_total_WLS_notrend")
graph_yoy_total_WLS_notrend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_total_WLS_notrend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_trend(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_total_OLS_trend")
# Event study graph
graph_yoy_total_OLS_trend <- event_study_graph(data = df_estimates,
graph_title = "yoy_total_OLS_trend")
graph_yoy_total_OLS_trend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_total_OLS_trend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_trend(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_total_WLS_trend")
# Event study graph
graph_yoy_total_WLS_trend <- event_study_graph(data = df_estimates ,
graph_title = "yoy_total_WLS_trend")
graph_yoy_total_WLS_trend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_total_WLS_trend <- df_estimates #for robustness check
results_yot_total_WLS_trend <- estimation_results # for only-post DID table# DID estimation
estimation_results <- dynamic_onlypost_DID_WLS_trend(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_total_WLS_trend")
# Event study graph
graph_yoy_total_WLS_trend_onlypost <- event_study_graph(data = df_estimates ,
graph_title = "yoy_total_WLS_trend")
ggplotly(graph_yoy_total_WLS_trend_onlypost)estimates_yoy_total_WLS_trend_onlypost <- df_estimates #for robustness check
results_yot_total_WLS_trend_onlypost <- estimation_results # for only-post DID table# DID estimation
estimation_results <- dynamic_DID_OLS_notrend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_total_OLS_notrend")
# Event study graph
graph_yoy_total_OLS_notrend_covar <- event_study_graph(data = df_estimates,
graph_title = "yoy_total_OLS_notrend")
graph_yoy_total_OLS_notrend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_total_OLS_notrend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_notrend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_total_WLS_notrend")
# Event study graph
graph_yoy_total_WLS_notrend_covar <- event_study_graph(data = df_estimates,
graph_title = "yoy_total_WLS_notrend")
graph_yoy_total_WLS_notrend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_total_WLS_notrend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_trend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_total_OLS_trend")
# Event study graph
graph_yoy_total_OLS_trend_covar <- event_study_graph(data = df_estimates,
graph_title = "yoy_total_OLS_trend")
graph_yoy_total_OLS_trend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_total_OLS_trend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_trend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_total_WLS_trend")
# Event study graph
graph_yoy_total_WLS_trend_covar <- event_study_graph(data = df_estimates,
graph_title = "yoy_total_WLS_trend")
graph_yoy_total_WLS_trend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_total_WLS_trend_covar <- df_estimates #for robustness check
results_yot_total_WLS_trend_covar <- estimation_results # for only-post DID table# DID estimation
estimation_results <- dynamic_onlypost_DID_WLS_trend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_total,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_total_WLS_trend")
# Event study graph
graph_yoy_total_WLS_trend_covar_onlypost <- event_study_graph(data = df_estimates ,
graph_title = "yoy_total_WLS_trend")
ggplotly(graph_yoy_total_WLS_trend_covar_onlypost)estimates_yoy_total_WLS_trend_covar_onlypost <- df_estimates #for robustness check
results_yot_total_WLS_trend_covar_onlypost <- estimation_results # for only-post DID table# DID estimation
estimation_results <- dynamic_DID_OLS_notrend(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "female_OLS_notrend")
# Event study graph
graph_female_OLS_notrend <- event_study_graph(data = df_estimates,
graph_title = "female_OLS_notrend")
graph_female_OLS_notrend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_female_OLS_notrend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_notrend(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates<- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "female_WLS_notrend")
# Event study graph
graph_female_WLS_notrend <- event_study_graph(data = df_estimates,
graph_title = "female_WLS_notrend")
graph_female_WLS_notrend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_female_WLS_notrend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_trend(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "female_OLS_trend")
# Event study graph
graph_female_OLS_trend <- event_study_graph(data = df_estimates,
graph_title = "female_OLS_trend")
graph_female_OLS_trend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_female_OLS_trend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_trend(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "female_WLS_trend")
# Event study graph
graph_female_WLS_trend <- event_study_graph(data = df_estimates,
graph_title = "female_WLS_trend")
graph_female_WLS_trend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_female_WLS_trend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_notrend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "female_OLS_notrend")
# Event study graph
graph_female_OLS_notrend_covar <- event_study_graph(data = df_estimates,
graph_title = "female_OLS_notrend")
graph_female_OLS_notrend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_female_OLS_notrend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_notrend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "female_WLS_notrend")
# Event study graph
graph_female_WLS_notrend_covar <- event_study_graph(data = df_estimates,
graph_title = "female_WLS_notrend")
graph_female_WLS_notrend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_female_WLS_notrend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_trend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "female_OLS_trend")
# Event study graph
graph_female_OLS_trend_covar <- event_study_graph(data = df_estimates,
graph_title = "female_OLS_trend")
graph_female_OLS_trend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_female_OLS_trend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_trend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "female_WLS_trend")
# Event study graph
graph_female_WLS_trend_covar <- event_study_graph(data = df_estimates,
graph_title = "female_WLS_trend")
graph_female_WLS_trend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_female_WLS_trend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_notrend(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_female_OLS_notrend")
# Event study graph
graph_yoy_female_OLS_notrend <- event_study_graph(data = df_estimates,
graph_title = "yoy_female_OLS_notrend")
graph_yoy_female_OLS_notrend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_female_OLS_notrend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_notrend(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_female_WLS_notrend")
# Event study graph
graph_yoy_female_WLS_notrend <- event_study_graph(data = df_estimates,
graph_title = "yoy_female_WLS_notrend")
graph_yoy_female_WLS_notrend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_female_WLS_notrend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_trend(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_female_OLS_trend")
# Event study graph
graph_yoy_female_OLS_trend <- event_study_graph(data = df_estimates,
graph_title = "yoy_female_OLS_trend")
graph_yoy_female_OLS_trend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_female_OLS_trend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_trend(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_female_WLS_trend")
# Event study graph
graph_yoy_female_WLS_trend <- event_study_graph(data = df_estimates,
graph_title = "yoy_female_WLS_trend")
graph_yoy_female_WLS_trend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_female_WLS_trend <- df_estimates #for robustness check
results_yot_female_WLS_trend <- estimation_results # for only-post DID table# DID estimation
estimation_results <- dynamic_onlypost_DID_WLS_trend(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_female_WLS_trend")
# Event study graph
graph_yoy_female_WLS_trend_onlypost <- event_study_graph(data = df_estimates ,
graph_title = "yoy_female_WLS_trend")
ggplotly(graph_yoy_female_WLS_trend_onlypost)estimates_yoy_female_WLS_trend_onlypost <- df_estimates #for robustness check
results_yot_female_WLS_trend_onlypost <- estimation_results # for only-post DID table# DID estimation
estimation_results <- dynamic_DID_OLS_notrend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_female_OLS_notrend")
# Event study graph
graph_yoy_female_OLS_notrend_covar <- event_study_graph(data = df_estimates,
graph_title = "yoy_female_OLS_notrend")
graph_yoy_female_OLS_notrend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_female_OLS_notrend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_notrend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_female_WLS_notrend")
# Event study graph
graph_yoy_female_WLS_notrend_covar <- event_study_graph(data = df_estimates,
graph_title = "yoy_female_WLS_notrend")
graph_yoy_female_WLS_notrend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_female_WLS_notrend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_trend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_female_OLS_trend")
# Event study graph
graph_yoy_female_OLS_trend_covar <- event_study_graph(data = df_estimates,
graph_title = "yoy_female_OLS_trend")
graph_yoy_female_OLS_trend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_female_OLS_trend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_trend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_female_WLS_trend")
# Event study graph
graph_yoy_female_WLS_trend_covar <- event_study_graph(data = df_estimates,
graph_title = "yoy_female_WLS_trend")
graph_yoy_female_WLS_trend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_female_WLS_trend_covar <- df_estimates #for robustness check
results_yot_female_WLS_trend_covar <- estimation_results # for only-post DID table# DID estimation
estimation_results <- dynamic_onlypost_DID_WLS_trend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_female,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_female_WLS_trend")
# Event study graph
graph_yoy_female_WLS_trend_covar_onlypost <- event_study_graph(data = df_estimates ,
graph_title = "yoy_female_WLS_trend")
ggplotly(graph_yoy_female_WLS_trend_covar_onlypost)estimates_yoy_female_WLS_trend_covar_onlypost <- df_estimates #for robustness check
results_yot_female_WLS_trend_covar_onlypost <- estimation_results # for only-post DID table# DID estimation
estimation_results <- dynamic_DID_OLS_notrend(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates<- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "male_OLS_notrend")
# Event study graph
graph_male_OLS_notrend <- event_study_graph(data = df_estimates,
graph_title = "male_OLS_notrend")
graph_male_OLS_notrend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_male_OLS_notrend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_notrend(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "male_WLS_notrend")
# Event study graph
graph_male_WLS_notrend <- event_study_graph(data = df_estimates,
graph_title = "male_WLS_notrend")
graph_male_WLS_notrend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_male_WLS_notrend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_trend(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "male_OLS_trend")
# Event study graph
graph_male_OLS_trend <- event_study_graph(data = df_estimates,
graph_title = "male_OLS_trend")
graph_male_OLS_trend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_male_OLS_trend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_trend(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "male_WLS_trend")
# Event study graph
graph_male_WLS_trend <- event_study_graph(data = df_estimates,
graph_title = "male_WLS_trend")
graph_male_WLS_trend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_male_WLS_trend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_notrend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "male_OLS_notrend")
# Event study graph
graph_male_OLS_notrend_covar <- event_study_graph(data = df_estimates,
graph_title = "male_OLS_notrend")
graph_male_OLS_notrend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_male_OLS_notrend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_notrend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "male_WLS_notrend")
# Event study graph
graph_male_WLS_notrend_covar <- event_study_graph(data = df_estimates,
graph_title = "male_WLS_notrend")
graph_male_WLS_notrend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_male_WLS_notrend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_trend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "male_OLS_trend")
# Event study graph
graph_male_OLS_trend_covar <- event_study_graph(data = df_estimates,
graph_title = "male_OLS_trend")
graph_male_OLS_trend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_male_OLS_trend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_trend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "male_WLS_trend")
# Event study graph
graph_male_WLS_trend_covar <- event_study_graph(data = df_estimates,
graph_title = "male_WLS_trend")
graph_male_WLS_trend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_male_WLS_trend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_notrend(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_male_OLS_notrend")
# Event study graph
graph_yoy_male_OLS_notrend <- event_study_graph(data = df_estimates,
graph_title = "yoy_male_OLS_notrend")
graph_yoy_male_OLS_notrend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_male_OLS_notrend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_notrend(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_male_WLS_notrend")
# Event study graph
graph_yoy_male_WLS_notrend <- event_study_graph(data = df_estimates,
graph_title = "yoy_male_WLS_notrend")
graph_yoy_male_WLS_notrend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_male_WLS_notrend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_trend(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_male_OLS_trend")
# Event study graph
graph_yoy_male_OLS_trend <- event_study_graph(data = df_estimates,
graph_title = "yoy_male_OLS_trend")
graph_yoy_male_OLS_trend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_male_OLS_trend <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_trend(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_male_WLS_trend")
# Event study graph
graph_yoy_male_WLS_trend <- event_study_graph(data = df_estimates,
graph_title = "yoy_male_WLS_trend")
graph_yoy_male_WLS_trend## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_male_WLS_trend <- df_estimates #for robustness check
results_yot_male_WLS_trend <- estimation_results # for only-post DID table# DID estimation
estimation_results <- dynamic_onlypost_DID_WLS_trend(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_male_WLS_trend")
# Event study graph
graph_yoy_male_WLS_trend_onlypost <- event_study_graph(data = df_estimates ,
graph_title = "yoy_male_WLS_trend")
ggplotly(graph_yoy_male_WLS_trend_onlypost)estimates_yoy_male_WLS_trend_onlypost <- df_estimates #for robustness check
results_yot_male_WLS_trend_onlypost <- estimation_results # for only-post DID table# DID estimation
estimation_results <- dynamic_DID_OLS_notrend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_male_OLS_notrend")
# Event study graph
graph_yoy_male_OLS_notrend_covar <- event_study_graph(data = df_estimates,
graph_title = "yoy_male_OLS_notrend")
graph_yoy_male_OLS_notrend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_male_OLS_notrend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_notrend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_male_WLS_notrend")
# Event study graph
graph_yoy_male_WLS_notrend_covar <- event_study_graph(data = df_estimates,
graph_title = "yoy_male_WLS_notrend")
graph_yoy_male_WLS_notrend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_male_WLS_notrend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_OLS_trend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_male_OLS_trend")
# Event study graph
graph_yoy_male_OLS_trend_covar <- event_study_graph(data = df_estimates,
graph_title = "yoy_male_OLS_trend")
graph_yoy_male_OLS_trend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_male_OLS_trend_covar <- df_estimates #for robustness check# DID estimation
estimation_results <- dynamic_DID_WLS_trend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_male_WLS_trend")
# Event study graph
graph_yoy_male_WLS_trend_covar <- event_study_graph(data = df_estimates,
graph_title = "yoy_male_WLS_trend")
graph_yoy_male_WLS_trend_covar## Warning: Removed 32 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
estimates_yoy_male_WLS_trend_covar <- df_estimates #for robustness check
results_yot_male_WLS_trend_covar <- estimation_results # for only-post DID table# DID estimation
estimation_results <- dynamic_onlypost_DID_WLS_trend_covar8Xcovid_months(dataset = df_analysis,
outcome_var = df_analysis$yoy_unemp_benefit_number_male,
treat_var = df_analysis$job_seeker_total_shock)
#texreg::screenreg(l = estimation_results , include.ci = FALSE, digits=3,)
# DID estimates and 90% CI
df_estimates <- DID_coefficients_main(DID_results = estimation_results,
treat_var = "job_seeker_total_shock",
estimation_label = "yoy_male_WLS_trend")
# Event study graph
graph_yoy_male_WLS_trend_covar_onlypost <- event_study_graph(data = df_estimates ,
graph_title = "yoy_male_WLS_trend")
ggplotly(graph_yoy_male_WLS_trend_covar_onlypost)estimates_yoy_male_WLS_trend_covar_onlypost <- df_estimates #for robustness check
results_yot_male_WLS_trend_covar_onlypost <- estimation_results # for only-post DID table#merge and label estimates data
estimates_total_bind <- dplyr::bind_rows(estimates_total_OLS_notrend,
estimates_total_WLS_notrend,
estimates_total_OLS_trend,
estimates_total_WLS_trend)
#change labels and reorder labels
estimates_total_bind <- estimates_labeling_main(estimates_total_bind)
# Display results
DT::datatable(estimates_total_bind) %>%
DT::formatRound(columns = c("estimate", "ci_lower", "ci_upper"), digits=3)#graph
graph_total_bind <- event_study_graph_bind_main(data = estimates_total_bind,
graph_title = "Total")
ggplotly(graph_total_bind)#merge and label estimates data
estimates_total_bind <- dplyr::bind_rows(estimates_total_OLS_notrend_covar,
estimates_total_WLS_notrend_covar,
estimates_total_OLS_trend_covar,
estimates_total_WLS_trend_covar)
#change labels and reorder labels
estimates_total_bind <- estimates_labeling_main(estimates_total_bind)
# Display results
DT::datatable(estimates_total_bind) %>%
DT::formatRound(columns = c("estimate", "ci_lower", "ci_upper"), digits=3)#graph
graph_total_bind_covar <- event_study_graph_bind_main(data = estimates_total_bind,
graph_title = "Total, with covar")
ggplotly(graph_total_bind_covar)#merge and label estimates data
estimates_yoy_total_bind <- dplyr::bind_rows(estimates_yoy_total_OLS_notrend,
estimates_yoy_total_WLS_notrend,
estimates_yoy_total_OLS_trend,
estimates_yoy_total_WLS_trend)
#change labels and reorder labels
estimates_yoy_total_bind <- estimates_labeling_main(estimates_yoy_total_bind)
# display results
DT::datatable(estimates_yoy_total_bind) %>%
DT::formatRound(columns = c("estimate", "ci_lower", "ci_upper"), digits=3)#graph
graph_yoy_total_bind <- event_study_graph_bind_main(data = estimates_yoy_total_bind,
graph_title = "Total, YOY")
ggplotly(graph_yoy_total_bind)#merge and label estimates data
estimates_yoy_total_bind <- dplyr::bind_rows(estimates_yoy_total_OLS_notrend_covar,
estimates_yoy_total_WLS_notrend_covar,
estimates_yoy_total_OLS_trend_covar,
estimates_yoy_total_WLS_trend_covar)
#change labels and reorder labels
estimates_yoy_total_bind <- estimates_labeling_main(estimates_yoy_total_bind)
# display results
DT::datatable(estimates_yoy_total_bind) %>%
DT::formatRound(columns = c("estimate", "ci_lower", "ci_upper"), digits=3)#graph
graph_yoy_total_bind_covar <- event_study_graph_bind_main(data = estimates_yoy_total_bind,
graph_title = "Total, YOY, with covar")
ggplotly(graph_yoy_total_bind_covar)#merge and label estimates data
estimates_female_bind <- dplyr::bind_rows(estimates_female_OLS_notrend,
estimates_female_WLS_notrend,
estimates_female_OLS_trend,
estimates_female_WLS_trend)
#change labels and reorder labels
estimates_female_bind <- estimates_labeling_main(estimates_female_bind)
# display results
DT::datatable(estimates_female_bind) %>%
DT::formatRound(columns = c("estimate", "ci_lower", "ci_upper"), digits=3)#graph
graph_female_bind <- event_study_graph_bind_main(data = estimates_female_bind,
graph_title = "Female")
ggplotly(graph_female_bind)#merge and label estimates data
estimates_female_bind <- dplyr::bind_rows(estimates_female_OLS_notrend_covar,
estimates_female_WLS_notrend_covar,
estimates_female_OLS_trend_covar,
estimates_female_WLS_trend_covar)
#change labels and reorder labels
estimates_female_bind <- estimates_labeling_main(estimates_female_bind)
# display results
DT::datatable(estimates_female_bind) %>%
DT::formatRound(columns = c("estimate", "ci_lower", "ci_upper"), digits=3)#graph
graph_female_bind_covar <- event_study_graph_bind_main(data = estimates_female_bind,
graph_title = "Female, with covar")
ggplotly(graph_female_bind_covar)#merge and label estimates data
estimates_yoy_female_bind <- dplyr::bind_rows(estimates_yoy_female_OLS_notrend,
estimates_yoy_female_WLS_notrend,
estimates_yoy_female_OLS_trend,
estimates_yoy_female_WLS_trend)
#change labels and reorder labels
estimates_yoy_female_bind <- estimates_labeling_main(estimates_yoy_female_bind)
# display results
DT::datatable(estimates_yoy_female_bind) %>%
DT::formatRound(columns = c("estimate", "ci_lower", "ci_upper"), digits=3)#graph
graph_yoy_female_bind <- event_study_graph_bind_main(data = estimates_yoy_female_bind,
graph_title = "Female, YOY")
ggplotly(graph_yoy_female_bind)#merge and label estimates data
estimates_yoy_female_bind <- dplyr::bind_rows(estimates_yoy_female_OLS_notrend_covar,
estimates_yoy_female_WLS_notrend_covar,
estimates_yoy_female_OLS_trend_covar,
estimates_yoy_female_WLS_trend_covar)
#change labels and reorder labels
estimates_yoy_female_bind <- estimates_labeling_main(estimates_yoy_female_bind)
# display results
DT::datatable(estimates_yoy_female_bind) %>%
DT::formatRound(columns = c("estimate", "ci_lower", "ci_upper"), digits=3)#graph
graph_yoy_female_bind_covar <- event_study_graph_bind_main(data = estimates_yoy_female_bind,
graph_title = "Female, YOY, with covar")
ggplotly(graph_yoy_female_bind_covar)#merge and label estimates data
estimates_male_bind <- dplyr::bind_rows(estimates_male_OLS_notrend,
estimates_male_WLS_notrend,
estimates_male_OLS_trend,
estimates_male_WLS_trend)
#change labels and reorder labels
estimates_male_bind <- estimates_labeling_main(estimates_male_bind)
# display results
DT::datatable(estimates_male_bind) %>%
DT::formatRound(columns = c("estimate", "ci_lower", "ci_upper"), digits=3)#graph
graph_male_bind <- event_study_graph_bind_main(data = estimates_male_bind,
graph_title = "Male")
ggplotly(graph_male_bind)#merge and label estimates data
estimates_male_bind <- dplyr::bind_rows(estimates_male_OLS_notrend_covar,
estimates_male_WLS_notrend_covar,
estimates_male_OLS_trend_covar,
estimates_male_WLS_trend_covar)
#change labels and reorder labels
estimates_male_bind <- estimates_labeling_main(estimates_male_bind)
# display results
DT::datatable(estimates_male_bind) %>%
DT::formatRound(columns = c("estimate", "ci_lower", "ci_upper"), digits=3)#graph
graph_male_bind_covar <- event_study_graph_bind_main(data = estimates_male_bind,
graph_title = "Male, with covar")
ggplotly(graph_male_bind_covar)#merge and label estimates data
estimates_yoy_male_bind <- dplyr::bind_rows(estimates_yoy_male_OLS_notrend,
estimates_yoy_male_WLS_notrend,
estimates_yoy_male_OLS_trend,
estimates_yoy_male_WLS_trend)
#change labels and reorder labels
estimates_yoy_male_bind <- estimates_labeling_main(estimates_yoy_male_bind)
# display results
DT::datatable(estimates_yoy_male_bind) %>%
DT::formatRound(columns = c("estimate", "ci_lower", "ci_upper"), digits=3)#graph
graph_yoy_male_bind <- event_study_graph_bind_main(data = estimates_yoy_male_bind,
graph_title = "Male, YOY")
ggplotly(graph_yoy_male_bind)#merge and label estimates data
estimates_yoy_male_bind <- dplyr::bind_rows(estimates_yoy_male_OLS_notrend_covar,
estimates_yoy_male_WLS_notrend_covar,
estimates_yoy_male_OLS_trend_covar,
estimates_yoy_male_WLS_trend_covar)
#change labels and reorder labels
estimates_yoy_male_bind <- estimates_labeling_main(estimates_yoy_male_bind)
# display results
DT::datatable(estimates_yoy_male_bind) %>%
DT::formatRound(columns = c("estimate", "ci_lower", "ci_upper"), digits=3)#graph
graph_yoy_male_bind_covar <- event_study_graph_bind_main(data = estimates_yoy_male_bind,
graph_title = "Male, YOY, with covar")
ggplotly(graph_yoy_male_bind_covar)#ggplotly
ggplotly(graph_yoy_total_bind)ggplotly(graph_yoy_total_bind_covar)ggplotly(graph_yoy_female_bind)ggplotly(graph_yoy_female_bind_covar)ggplotly(graph_yoy_male_bind) ggplotly(graph_yoy_male_bind_covar)#Legendの表示
graph_for_legend <- graph_total_bind +
theme(legend.position = 'bottom', # Adjust x axis label
legend.title = element_text(colour = "black", size = 20),
legend.text = element_text(color = "black", size = 20))
graph_for_legend #extract legend
legend_model_types <- ggpubr::get_legend(graph_for_legend)
legend_model_types <- ggpubr::as_ggplot(legend_model_types)
legend_model_types#2行Legendの表示
graph_for_legend_2row <- graph_total_bind +
theme(legend.position = 'bottom', # Adjust x axis label
legend.title = element_text(colour = "black", size = 20),
legend.text = element_text(color = "black", size = 20))+
guides(color = guide_legend(nrow = 2, byrow = TRUE)) #legendを二行に変更 2021Sep7 Waki
graph_for_legend_2row #extract legend
legend_2row_model_types <- ggpubr::get_legend(graph_for_legend_2row)
legend_2row_model_types <- ggpubr::as_ggplot(legend_2row_model_types)
legend_2row_model_typesグラフを統合して論文用に保存。 ### graph size
dpi_num <- 100
width_num <- 15
height_num <- 18ymin <- - 30
ymax <- 75
ymin_num <- - 25
ymax_num <- 75
interval <- 25
graph_total_WLS_trend <- graph_total_WLS_trend +
labs(title = "(a) Total unemployment benefit recipients") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_total_WLS_trend_covar <- graph_total_WLS_trend_covar +
labs(title = "(b) Total unemployment benefit recipients, with covaraites") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_female_WLS_trend <- graph_female_WLS_trend +
labs(title = "(c) Female unemployment benefit recipients")+
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_female_WLS_trend_covar <- graph_female_WLS_trend_covar +
labs(title = "(d) Female unemployment benefit recipients, with covaraites") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_male_WLS_trend <- graph_male_WLS_trend +
labs(title = "(e) Male unemployment benefit recipients")+
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_male_WLS_trend_covar <- graph_male_WLS_trend_covar +
labs(title = "(f) Male unemployment benefit recipients, with covaraites") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph <- (graph_total_WLS_trend | graph_total_WLS_trend_covar) /
(graph_female_WLS_trend | graph_female_WLS_trend_covar) /
(graph_male_WLS_trend | graph_male_WLS_trend_covar)
graph## Warning: Removed 43 rows containing missing values (geom_point).
## Warning: Removed 35 row(s) containing missing values (geom_path).
## Warning: Removed 45 rows containing missing values (geom_point).
## Warning: Removed 34 row(s) containing missing values (geom_path).
## Warning: Removed 44 rows containing missing values (geom_point).
## Warning: Removed 35 row(s) containing missing values (geom_path).
## Warning: Removed 46 rows containing missing values (geom_point).
## Warning: Removed 33 row(s) containing missing values (geom_path).
## Warning: Removed 39 rows containing missing values (geom_point).
## Warning: Removed 35 row(s) containing missing values (geom_path).
## Warning: Removed 39 rows containing missing values (geom_point).
## Warning: Removed 34 row(s) containing missing values (geom_path).
#保存
ggsave(file = "output/graph_job_seeker_total_shock_on_UIbenefit_WLStrends.pdf", plot = graph,
dpi = dpi_num, width = width_num, height = height_num) ## Warning: Removed 43 rows containing missing values (geom_point).
## Warning: Removed 35 row(s) containing missing values (geom_path).
## Warning: Removed 45 rows containing missing values (geom_point).
## Warning: Removed 34 row(s) containing missing values (geom_path).
## Warning: Removed 44 rows containing missing values (geom_point).
## Warning: Removed 35 row(s) containing missing values (geom_path).
## Warning: Removed 46 rows containing missing values (geom_point).
## Warning: Removed 33 row(s) containing missing values (geom_path).
## Warning: Removed 39 rows containing missing values (geom_point).
## Warning: Removed 35 row(s) containing missing values (geom_path).
## Warning: Removed 39 rows containing missing values (geom_point).
## Warning: Removed 34 row(s) containing missing values (geom_path).
ymin <- - 30
ymax <- 100
ymin_num <- - 25
ymax_num <- 100
interval <- 25
graph_yoy_total_WLS_trend <- graph_yoy_total_WLS_trend +
labs(title = "(a) Total") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_yoy_total_WLS_trend_covar <- graph_yoy_total_WLS_trend_covar +
labs(title = "(b) Total, with covaraites") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_yoy_female_WLS_trend <- graph_yoy_female_WLS_trend +
labs(title = "(c) Female") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_yoy_female_WLS_trend_covar <- graph_yoy_female_WLS_trend_covar +
labs(title = "(d) Female, with covaraites") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_yoy_male_WLS_trend <- graph_yoy_male_WLS_trend +
labs(title = "(e) Male") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_yoy_male_WLS_trend_covar <- graph_yoy_male_WLS_trend_covar +
labs(title = "(f) Male, with covaraites") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph <- (graph_yoy_total_WLS_trend | graph_yoy_total_WLS_trend_covar) /
(graph_yoy_female_WLS_trend | graph_yoy_female_WLS_trend_covar) /
(graph_yoy_male_WLS_trend | graph_yoy_male_WLS_trend_covar)
graph## Warning: Removed 36 rows containing missing values (geom_point).
## Warning: Removed 35 row(s) containing missing values (geom_path).
## Warning: Removed 37 rows containing missing values (geom_point).
## Warning: Removed 33 row(s) containing missing values (geom_path).
## Warning: Removed 43 rows containing missing values (geom_point).
## Warning: Removed 35 row(s) containing missing values (geom_path).
## Warning: Removed 47 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
## Warning: Removed 35 rows containing missing values (geom_point).
## Warning: Removed 35 row(s) containing missing values (geom_path).
## Warning: Removed 34 rows containing missing values (geom_point).
## Warning: Removed 34 row(s) containing missing values (geom_path).
#保存
ggsave(file = "output/graph_job_seeker_total_shock_on_yoy_UIbenefit_WLStrends.pdf", plot = graph,
dpi = dpi_num, width = width_num, height = height_num) ## Warning: Removed 36 rows containing missing values (geom_point).
## Warning: Removed 35 row(s) containing missing values (geom_path).
## Warning: Removed 37 rows containing missing values (geom_point).
## Warning: Removed 33 row(s) containing missing values (geom_path).
## Warning: Removed 43 rows containing missing values (geom_point).
## Warning: Removed 35 row(s) containing missing values (geom_path).
## Warning: Removed 47 rows containing missing values (geom_point).
## Warning: Removed 32 row(s) containing missing values (geom_path).
## Warning: Removed 35 rows containing missing values (geom_point).
## Warning: Removed 35 row(s) containing missing values (geom_path).
## Warning: Removed 34 rows containing missing values (geom_point).
## Warning: Removed 34 row(s) containing missing values (geom_path).
ymin <- - 200
ymax <- 300
ymin_num <- - 200
ymax_num <- 300
interval <- 50
graph_total_bind <- graph_total_bind +
labs(title = "(a) Total unemployment benefit recipients") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_total_bind_covar <- graph_total_bind_covar +
labs(title = "(b) Total unemployment benefit recipients, with covaraites") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_female_bind <- graph_female_bind +
labs(title = "(c) Female unemployment benefit recipients")+
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_female_bind_covar <- graph_female_bind_covar +
labs(title = "(d) Female unemployment benefit recipients, with covaraites") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_male_bind <- graph_male_bind +
labs(title = "(e) Male unemployment benefit recipients")+
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_male_bind_covar <- graph_male_bind_covar +
labs(title = "(f) Male unemployment benefit recipients, with covaraites") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph <- (graph_total_bind | graph_total_bind_covar) /
(graph_female_bind| graph_female_bind_covar) /
(graph_male_bind| graph_male_bind_covar)/
legend_model_types+
plot_layout(heights = c(2, 2, 2, 0.5)) #0.3から0.5へ変更 2021Sep7 Waki
graph#保存
ggsave(file = "output/graph_job_seeker_total_shock_on_UIbenefit_robust.pdf", plot = graph,
dpi = dpi_num, width = width_num, height = height_num) ymin <- - 330
ymax <- 400
ymin_num <- - 300
ymax_num <- 400
interval <- 100
graph_yoy_total_bind <- graph_yoy_total_bind +
labs(title = "(a) Total") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_yoy_total_bind_covar <- graph_yoy_total_bind_covar +
labs(title = "(b) Total, with covaraites") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_yoy_female_bind <- graph_yoy_female_bind +
labs(title = "(c) Female") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_yoy_female_bind_covar <- graph_yoy_female_bind_covar +
labs(title = "(d) Female, with covaraites") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_yoy_male_bind <- graph_yoy_male_bind +
labs(title = "(e) Male") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph_yoy_male_bind_covar <- graph_yoy_male_bind_covar +
labs(title = "(f) Male, with covaraites") +
scale_y_continuous(limit = c(ymin, ymax), breaks=seq(ymin_num, ymax_num, interval))
graph <- (graph_yoy_total_bind | graph_yoy_total_bind_covar) /
(graph_yoy_female_bind| graph_yoy_female_bind_covar) /
(graph_yoy_male_bind| graph_yoy_male_bind_covar)/
legend_model_types +
plot_layout(heights = c(2, 2, 2, 0.5)) #0.3から0.5へ変更 2021Sep7 Waki
graph#保存
ggsave(file = "output/graph_job_seeker_total_shock_on_yoy_UIbenefit_robust.pdf", plot = graph,
dpi = dpi_num, width = width_num, height = height_num) options("modelsummary_format_numeric_latex" = "plain")
# 列の選択 column order
# 男女合計、女性、男性、YOYのみ, monthlyhのみ
rows_MONTH <- tribble(~name, ~"(1)", ~"(2)", ~"(3)", ~"(4)", ~"(5)", ~"(6)",
"Ref. month", "\\footnotesize{Jan.2020}", "\\footnotesize{$\\leq$Jan.2020}", "\\footnotesize{Jan.2020}", "\\footnotesize{$\\leq$Jan.2020}","\\footnotesize{Jan.2020}", "\\footnotesize{$\\leq$Jan.2020}")
## results list
table_results_MONTH <- list()
table_results_MONTH[["(1)"]] <- results_yot_total_WLS_trend
table_results_MONTH[["(2)"]] <- results_yot_total_WLS_trend_onlypost
table_results_MONTH[["(3)"]] <- results_yot_female_WLS_trend
table_results_MONTH[["(4)"]] <- results_yot_female_WLS_trend_onlypost
table_results_MONTH[["(5)"]] <- results_yot_male_WLS_trend
table_results_MONTH[["(6)"]] <- results_yot_male_WLS_trend_onlypost
## HTML table
estimates_table_MONTH(df = table_results_MONTH,
rows = rows_MONTH,
title_words = "UIbenefit",
gof = gm,
output_style = "html") %>%
kableExtra::add_header_above(c(" " = 1, "Total" = 2, "Female" = 2, "Male" = 2))
## Latex table
estimates_table_MONTH(df = table_results_MONTH,
rows = rows_MONTH,
gof = gm,
title_words = "DID estimates for suicide rates\\label{tab:DID_unemploy_on_suicide}",
output_style = "latex") %>%
kableExtra::add_header_above(c(" " = 1, "Total" = 2, "Female" = 2, "Male" = 2)) %>%
kableExtra::add_footnote(c("Notes: Robust standard errors are clustered at the prefecture level and the number of clusters (i.e. prefectures) is 47. The treatment variable is the COVID-19-induced employment shock, which is calculated as equation \\eqref{eq:employment_shock}. Estimates are obtained based on equation \\eqref{eq:did_model_ver2} with WLS estimation weighted by prefecture population size."),threeparttable = TRUE, notation = "none",escape = FALSE) %>%
kableExtra::column_spec(2:7, width = "1.5cm") %>%
kableExtra::save_kable("output/job_seeker_total_shock_on_UIbenefit_robust_tables.tex")# 列の選択 column order
# 男女合計、女性、男性、YOYのみ, monthlyhのみ
rows_MONTH <- tribble(~name, ~"(1)", ~"(2)", ~"(3)", ~"(4)", ~"(5)", ~"(6)",
"Ref. month", "\\footnotesize{Jan.2020}", "\\footnotesize{$\\leq$Jan.2020}", "\\footnotesize{Jan.2020}", "\\footnotesize{$\\leq$Jan.2020}","\\footnotesize{Jan.2020}", "\\footnotesize{$\\leq$Jan.2020}")
## results list
table_results_MONTH <- list()
table_results_MONTH[["(1)"]] <- results_yot_total_WLS_trend_covar
table_results_MONTH[["(2)"]] <- results_yot_total_WLS_trend_covar_onlypost
table_results_MONTH[["(3)"]] <- results_yot_female_WLS_trend_covar
table_results_MONTH[["(4)"]] <- results_yot_female_WLS_trend_covar_onlypost
table_results_MONTH[["(5)"]] <- results_yot_male_WLS_trend_covar
table_results_MONTH[["(6)"]] <- results_yot_male_WLS_trend_covar_onlypost
## HTML table
estimates_table_MONTH(df = table_results_MONTH,
rows = rows_MONTH,
title_words = "UIbenefit",
gof = gm,
output_style = "html") %>%
kableExtra::add_header_above(c(" " = 1, "Total" = 2, "Female" = 2, "Male" = 2))
## Latex table
estimates_table_MONTH(df = table_results_MONTH,
rows = rows_MONTH,
gof = gm,
title_words = "DID estimates for suicide rates\\label{tab:DID_unemploy_on_suicide}",
output_style = "latex") %>%
kableExtra::add_header_above(c(" " = 1, "Total" = 2, "Female" = 2, "Male" = 2)) %>%
kableExtra::add_footnote(c("Notes: Robust standard errors are clustered at the prefecture level and the number of clusters (i.e. prefectures) is 47. The treatment variable is the COVID-19-induced employment shock, which is calculated as equation \\eqref{eq:employment_shock}. Estimates are obtained based on equation \\eqref{eq:did_model_ver2} with WLS estimation weighted by prefecture population size."),threeparttable = TRUE, notation = "none",escape = FALSE) %>%
kableExtra::column_spec(2:7, width = "1.5cm") %>%
kableExtra::save_kable("output/job_seeker_total_shock_on_UIbenefit_robust_covar_tables.tex")